0 // 如果没有通过拦截器配置域名的话，可以在这里写上完整的URL(加上域名部分)
let getProductInfoUrl = '/api/product/getProductInfo';
let CodeAuthUrl = '/open-api/zfb/auth'
let PhoneUrl = '/open-api/zfb/getPhone'
let listProductUrl = '/open-api/zfb/listProduct'
let cardModelDetailUrl = '/open-api/zfb/cardModelDetail'
let QrCodeUrl='/open-api/zfb/getQrCode'
let createOrderUrl='/open-api/zfb/createOrder'
let prepayUrl='/open-api/zfb/prepay'
let queryOrderUrl='/open-api/zfb/queryOrder'
let recommendProductUrl='/open-api/zfb/recommendProduct'
let listOrderUrl='/open-api/zfb/listOrder'
let userCardListUrl = '/zhy-api/cardBag/userCardList'
let qrAndUserInfoUrl='/zhy-api/cardBag/qrAndUserInfo'
let listCardTypeUrl='zhy-api/cardBag/listCardType'
let bindUrl='zhy-api/cardBag/bind'
let cardResourceUrl='zhy-api/cardBag/cardResource'
let secnicDetailUrl='zhy-api/cardBag/secnicDetail'
let createCardQRCodeUrl='zhy-api/cardQRCode/createCardQRCode'
let sendCardBindVerifyCodeUrl='zhy-api/sms/sendCardBindVerifyCode'
let appointRecordUrl='zhy-api/cardBag/appointRecord'
let appointUrl='zhy-api/cardBag/appoint'
let cancelAppointUrl='zhy-api/cardBag/cancelAppoint'
let OrderUrl='/open-api/zfb/getOrder'
let queryZfbzdOrderUrl='/open-api/zfb/queryZfbzdOrder'
let getCouponTemplateListUrl='open-api/promotion/couponTemplate/getCouponTemplateList'
let getCouponTemplateUrl='open-api/promotion/couponTemplate/getCouponTemplate'
let cardModelDetailsUrl='/open-api/zfb/cardModelDetails'
let takeCouponUrl ='open-api/promotion/coupon/take'
let couponPageUrl ='open-api/promotion/coupon/couponPage'
let getCouponUrl='open-api/promotion/coupon/getCoupon'
let getCouponByGoodsIdUrl='open-api/promotion/coupon/getCouponByGoodsId'
let getQrByApiUrl='open-api/ybx/getQrByApi'
//单票

let queryTicketsPageUrl='open-api/tickets/queryTicketsPage'
// 此处第二个参数vm，就是我们在页面使用的this，你可以通过vm获取vuex等操作，更多内容详见uView对拦截器的介绍部分：
// https://uviewui.com/js/http.html#%E4%BD%95%E8%B0%93%E8%AF%B7%E6%B1%82%E6%8B%A6%E6%88%AA%EF%BC%9F
const install = (Vue, vm) => {
	// 此处没有使用传入的params参数
	let getProductInfo = (params = {}) => vm.$u.post(`${getProductInfoUrl}?id=${params.id}`, {});
    let getCodeAuthUrl = (params = {}) => vm.$u.post(`${CodeAuthUrl}?code=${params.code}`, {});
	let getPhoneUrl = (params = {}) => vm.$u.post(`${PhoneUrl}?encryptContent=${params.encryptContent}&openId=${params.openId}`, {});
    let getListProductUrl = (params = {}) => vm.$u.post(`${listProductUrl}?type=${params.type}`, {});
	let getCardModelDetailUrl = (params = {}) => vm.$u.post(`${cardModelDetailUrl}?goodsId=${params.goodsId}`, {});
	let getQrCodeUrl = (params = {}) => vm.$u.post(`${QrCodeUrl}`, params);
	let postCreateOrderUrl = (params = {}) => vm.$u.post(`${createOrderUrl}`, params);
	let getPrepayUrl = (params = {}) => vm.$u.post(`${prepayUrl}`, params);
	let getQueryOrderUrl = (params = {}) => vm.$u.post(`${queryOrderUrl}`, params);
	let getRecommendProductUrl= (params = {}) => vm.$u.post(`${recommendProductUrl}`, params);
	let getListOrderUrl= (params = {}) => vm.$u.post(`${listOrderUrl}`, params);
	let getUserCardList = (params = {}) => vm.$u.post(`${userCardListUrl}`, params);
	let qrAndUserInfo = (params = {}) => vm.$u.post(`${qrAndUserInfoUrl}`, params);
	let listCardType = (params = {}) => vm.$u.post(`${listCardTypeUrl}?saleChannel=${params.saleChannel}`, {});
	let postBind = (params = {}) => vm.$u.post(`${bindUrl}`, params);
	let getCardResource = (params = {}) => vm.$u.post(`${cardResourceUrl}`, params);
	let getecnicDetail = (params = {}) => vm.$u.post(`${secnicDetailUrl}`, params);
	let createCardQRCode = (params = {}) => vm.$u.post(`${createCardQRCodeUrl}`, params);
	let sendCardBindVerifyCode = (params = {}) => vm.$u.post(`${sendCardBindVerifyCodeUrl}`, params);
	let getAppointRecord = (params = {}) => vm.$u.post(`${appointRecordUrl}`, params);
	let postAppoint = (params = {}) => vm.$u.post(`${appointUrl}`, params);
	let cancelAppoint = (params = {}) => vm.$u.post(`${cancelAppointUrl}`, params);
	let getOrderUrl = (params = {}) => vm.$u.post(`${OrderUrl}?orderId=${params.orderId}`, {});	
	let getQueryZfbzdOrder = (params = {}) => vm.$u.post(`${queryZfbzdOrderUrl}?orderNo=${params.orderNo}`, {});	
	let getCouponTemplateList = (params = {}) => vm.$u.post(`${getCouponTemplateListUrl}`,params);	
	let getCouponTemplate = (params = {}) => vm.$u.post(`${getCouponTemplateUrl}`,params);	
    let cardModelDetails = (params = {}) => vm.$u.post(`${cardModelDetailsUrl}?goodsIds=${params.goodsIds}`,{});
	let takeCoupon = (params = {}) => vm.$u.post(`${takeCouponUrl}`,params);	
	let couponPage = (params = {}) => vm.$u.post(`${couponPageUrl}`,params);
	let getCoupon = (params = {}) => vm.$u.post(`${getCouponUrl}`,params);
	let getCouponByGoodsId = (params = {}) => vm.$u.post(`${getCouponByGoodsIdUrl}`,params);
	let getQrByApi = (params = {}) => vm.$u.post(`${getQrByApiUrl}`, params);
	let queryTicketsPage = (params = {}) => vm.$u.post(`${queryTicketsPageUrl}`, params);
	
	vm.$u.api = {
		getCodeAuthUrl,
		getPhoneUrl,
		getListProductUrl,
		getCardModelDetailUrl,
		getQrCodeUrl,
		postCreateOrderUrl,
		getPrepayUrl,
		getQueryOrderUrl,
		getRecommendProductUrl,
		getListOrderUrl,
		getUserCardList,
		qrAndUserInfo,
		listCardType,
		postBind,
		getCardResource,
		getecnicDetail,
		createCardQRCode,
		sendCardBindVerifyCode,
		getAppointRecord,
		postAppoint,
		cancelAppoint,
		getOrderUrl,
		getQueryZfbzdOrder,
		getCouponTemplateList,
		getCouponTemplate,
		cardModelDetails,
		takeCoupon,
		couponPage,
		getCoupon,
		getCouponByGoodsId,
		getQrByApi,

	};
}

export default {
	install
}